package homework.three;

public class Car extends Bx01 {
    public int number;
    public double price;
    public double money;
    public Car(int number,double price){
        this.number=number;
        this.price=price;
    }

    @Override
    public double add() {
        if (number==0){
            money=price*0.02;
        }
        return money;
    }
}
